﻿// petrk.cpp : 定义控制台应用程序的入口点。
//
#include "petrk.h"

int main(int argc, char* argv[])
{
	//gen_hash_seeds( 20000 );
	//return 0;

	if( argc < 2 ) return E_INVALIDARG;

	if( argc == 2 )
	{
		std::string file_name = argv[1];
		file_name.append( ".trk" );
		FILE * ofo = fopen( file_name.c_str(), "w" );
		if( !ofo ) return E_FAIL;
		long lr = write_mag_file( argv[1], ofo );
		fclose( ofo );
		return lr;
	}
	else if( argc == 3 )
	{
		return compare_pe_files( argv[1], argv[2] );
	}
	return E_INVALIDARG;
}



